#/bin/bash

rm -f LOCALIZE
STRING=
MINLEN=1

SRC_DIRS=src

for dir in ${SRC_DIRS}
do
	cd "${dir}"
	for i in *[.m,.M,.mm,.MM]
	do
    	STRING=`cat ${i} | grep NSLocalizedString | cut -d \@ -f 2 | cut -d \" -f 2`
	    LEN=${#STRING}
    	if [ "$LEN" -gt "$MINLEN" ] ; then
			echo "In file: ${i}" >> ../LOCALIZE
			echo "${STRING}" >> ../LOCALIZE
			echo >> ../LOCALIZE
	    fi
	done
	cd ..
done
